<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>

</body>
<script>
    // 3、模仿1到10的和，来计算1*2*3*...*10的结果

    // 声明阶乘变量
    let sum = 1;
    for (let i = 2; i <= 10; i++) {
        sum *= i;
    }

    // 控制台打印
    console.log(sum);
</script>

</html>